package wangjg.commons.character;

public class Html {
	public String filterAttributes(String element, String content) {
		String pattern = element + "\\s?=\\s?(['\"][^'\"]*?['\"]|[^'\"]\\S*)";
		content = content.replaceAll(pattern, "");
		return content;
	}

	public String filterTag(String element, String content) {
		String pattern = "<" + element + "[^>]*>|</" + element + ">";
		content = content.replaceAll(pattern, "");
		return content;
	}

}
